<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title>demo</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport"
          content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
    <link rel="stylesheet" href="layui/css/layui.css" media="all">
    <link rel="stylesheet" href="css/cyType.css" media="all">
    <link rel="stylesheet" href="css/cyStyle.css" media="all">
    <link rel="stylesheet" href="css/font-awesome.min.css" media="all">
    <script src="layui/layui.js" type="text/javascript" charset="utf-8"></script>
    <script src="js/jquery-1.10.2.min.js" type="text/javascript" charset="utf-8"></script>

    <script>
        if(!/^http(s*):\/\//.test(location.href)){
            alert('请部署到localhost上查看该演示');
        }
    </script>

    <script src="js/utils.js" type="text/javascript" charset="utf-8"></script>
    <script src="js/transferTool.js" type="text/javascript" charset="utf-8"></script>

</head>
<body>
<div class="layui-input-normal layui-form" style="margin:100px 580px;">
    <button class="layui-btn" lay-submit="" lay-filter="submitForm" ><i class="fa fa-floppy-o">&nbsp;</i>提交表单</button>
    <div cyType="transferTool" cyProps="url:'json/list.json'"   name="province[]" value="1111210000,1111340000"></div>
    <div cyType="transferTool" cyProps="url:'json/list.json',disabled:'1111210000,1111220000,1111230000'"   name="test[]" value="1111340000"></div>
</div>

<script>
    layui.use('form', function () {
        var form = layui.form;

        //监听提交///保存或修改
        form.on('submit(submitForm)', function (data) {
            layer.alert(JSON.stringify(data.field));
            return false;
        });

    });

</script>
</body>
</html>